using System;

namespace OrbitOne.GoogleCustomSearch.QueryParameters
{
    /// <summary>
    /// Required. The cx parameter specifies a unique code that identifies a custom search engine. 
    /// You must specify a Custom Search Engine using the cx parameter to retrieve search results from that CSE.
    /// eg.: q=Frodo&cx=00255077836266642015:u-scht7a-8i
    /// </summary>
    public class CX : QueryParameter
    {
        private string value;
        public override string Name
        {
            get { return "cx"; }
        }

        public override string Value
        {
            get { return value; }
            set 
            {
                if(value==null||value==string.Empty)
                {
                    throw new ArgumentException("cx value");

                }
                this.value = value;
            }
        }
    }
}
